package com.lanhai.longheng.beans;
 
import com.lanhai.longheng.enums.AgvCurrentTransEnum;

/**
 * 小车数据定义
 * 
 * @author zhengwei
 *
 */ 
public class AgvBean  {
	 
	// 基础数据部分
	private int agvId;
	private int port;
	private String ip; 

	// 变动数据
	private long areaId; 
	private String nextProcess;// 下一道工序
	private int currentX;
	private int currentY; 
	private AgvCurrentTransEnum currentTrans; //当前需要传输的状态
	private String nextNode; //下一个目的地
	
	private boolean finishTrans;  //传输完成标识，是给二维码做判断的
	 private int specialline;
	 
	 
	private int nextRoad; //下一条路线（退出机台时使用）
	private long nextDeviceid;
 
	private String lastCmd; //最后发送的指令
	private int cmdtime=0;  //最后指令发送次数
	   
	private boolean upHasTrans;
	private boolean downHasTrans; 
	private String currentDo;
	
	
	
	
	public AgvBean copy() {
		AgvBean obj=new AgvBean();
		obj.setCmdtime(cmdtime);
		obj.setLastCmd(lastCmd); 
		obj.setNextDeviceid(nextDeviceid);
		obj.setNextNode(nextNode);
		obj.setSpecialline(specialline);
		obj.setFinishTrans(finishTrans);
		obj.setNextRoad(nextRoad);
		obj.setCurrentTrans(currentTrans);
		obj.setCurrentX(currentX);
		obj.setCurrentY(currentY);
		obj.setAgvId(agvId); 
		obj.setPort(port);
		obj.setIp(ip);
		obj.setAreaId(areaId);
		obj.setNextProcess(nextProcess); 
		obj.setUpHasTrans(upHasTrans);
		obj.setDownHasTrans(downHasTrans);
		obj.setCurrentDo(currentDo);
		return obj;
	}
	

	public String getCurrentDo() {
		return currentDo;
	}


	public void setCurrentDo(String currentDo) {
		this.currentDo = currentDo;
	}


	public long getNextDeviceid() {
		return nextDeviceid;
	}

	public void setNextDeviceid(long nextDeviceid) {
		this.nextDeviceid = nextDeviceid;
	}

	public void addTime() {
		cmdtime++;
	}
	 

	public boolean isUpHasTrans() {
		return upHasTrans;
	}


	public void setUpHasTrans(boolean upHasTrans) {
		this.upHasTrans = upHasTrans;
	}


	public boolean isDownHasTrans() {
		return downHasTrans;
	}


	public void setDownHasTrans(boolean downHasTrans) {
		this.downHasTrans = downHasTrans;
	}

 
 
	public int getNextRoad() {
		return nextRoad;
	}

	public void setNextRoad(int nextRoad) {
		this.nextRoad = nextRoad;
	}

	public String getLastCmd() {
		return lastCmd;
	}

	public void setLastCmd(String lastCmd) {
		this.lastCmd = lastCmd;
	}

 
 

	public int getCmdtime() {
		return cmdtime;
	}

	public void setCmdtime(int cmdtime) {
		this.cmdtime = cmdtime;
	}

	public int getAgvId() {
		return agvId;
	}

	public void setAgvId(int agvId) {
		this.agvId = agvId;
	}

	public long getAreaId() {
		return areaId;
	}

	public void setAreaId(long areaId) {
		this.areaId = areaId;
	}

  

	public String getNextProcess() {
		return nextProcess;
	}

	public void setNextProcess(String nextProcess) {
		this.nextProcess = nextProcess;
	}

	public int getCurrentX() {
		return currentX;
	}

	public void setCurrentX(int currentX) {
		this.currentX = currentX;
	}

	public int getCurrentY() {
		return currentY;
	}

	public void setCurrentY(int currentY) {
		this.currentY = currentY;
	}
 
	public int getPort() {
		return port;
	}

	public void setPort(int port) {
		this.port = port;
	}

	public String getIp() {
		return ip;
	}

	public void setIp(String ip) {
		this.ip = ip;
	}
 
	public int getSpecialline() {
		return specialline;
	}

	public void setSpecialline(int specialline) {
		this.specialline = specialline;
	}

	public AgvCurrentTransEnum getCurrentTrans() {
		return currentTrans;
	}

	public void setCurrentTrans(AgvCurrentTransEnum currentTrans) {
		this.currentTrans = currentTrans;
	}

 

	public String getNextNode() {
		return nextNode;
	}

	public void setNextNode(String nextNode) {
		this.nextNode = nextNode;
	}

	public boolean isFinishTrans() {
		return finishTrans;
	}

	public void setFinishTrans(boolean finishTrans) {
		this.finishTrans = finishTrans;
	}

	 

}
